<!doctype html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="stylesheet" href="../../css/mui.min.css">
		<link rel="stylesheet" href="../../css/mui.picker.min.css" />
		<link rel="stylesheet" href="../../css/iconfont.css">
		<style>
			.mui-content-padded{margin:5px 0 0 0;}
			.mui-row-list span{float: left; line-height:33px; width:20%;}
			.mui-row-list select{float: left; line-height:14px; font-size:14px; margin-top:2px; margin-left: 5px;}
			.mui-btn-block{margin-bottom:0; padding:6px;}
			.mui-col-sm-12{ border-top: 1px solid #D1D1D1; width:100%; padding-top:5px; font-size:14px;}
			input{text-align: left;}
			input[type="text"]{height:30px; margin-bottom: 5px;}
			input[type="text"],input[type="number"]{height:26px; padding: 0;border-width:0; border-bottom: #dddddd 1px solid; margin-bottom:0;background:none;}
			input[readonly="readonly"]{ text-align: left; padding-left: 5px; padding-right: 0;}
			input{border-width: 0; height: 26px; float: right; text-align: right; padding-right: 15px;}
			form:before{ background: none !important; border: none !important;}
			
			.mui-switch:before {content: '无'; color: #fff;}
			.mui-switch{border-color: #fd933b;background-color: #fd933b;border-width: 1px;}
			.mui-switch.mui-active:before {content: '有'; color: #fff;}
			.mui-switch.mui-active {border-color: #007AFF;background-color: #007AFF;}
			
			.mui-switch.new1:before {content: '无'; color: #fff;}
			.mui-switch.new1{border-color: #fd933b;background-color: #fd933b;border-width: 1px;}
			.mui-switch.mui-active.new1:before {content: '有'; color: #fff;}
			.mui-switch.mui-active.new1 {border-color: #007AFF;background-color: #007AFF;}
			
			.mui-switch.new2:before {content: '未见异常'; color: #fff;}
			.mui-switch.new2{border-width: 1px; width:95px;border-color: #007AFF;background-color: #007AFF;}
			.mui-switch.mui-active.new2:before {content: '异常'; color: #fff;}
			.mui-switch.mui-active.new2 {border-color: #fd933b;background-color: #fd933b;}
			.mui-switch.mui-active.new2 .mui-switch-handle{
				-webkit-transform: translate(63px,0);
				transform: translate(63px,0);
			}
			
			.mui-table-view-cell.mui-active{ display:block;}
			.mui-table-view-cell-1{padding: 5px 15px; position: relative; overflow: hidden;}
			.border0{border-width: 0; border-bottom: #dddddd 1px solid;}
			.ui-alert{font-size: 14px;}
			#Popup {
				width: 0px;
				height: 0px;
				background: red;
				position: fixed;
				top: 70%;
				left: 50%;
			}
			.mui-popover{
				width: 300px;
			}
			.mui-popover .mui-popover-arrow:after {
				width: 0px;
			}
			/**/

			/**/
			.popover-cont ul{
				margin-top: 5px; 
				margin: 0; 
				padding: 0; 
				list-style: none; 
				background: #ffffff;
			}
			.table{
				width: 100%;
			}
			.thead{
				width: 100%;
				border: 1px solid #007AFF;
			}
			.thead tr{
				 width: 100%; 
				 background-color: #007AFF;
				 height: 20px;
			}
			.thead tr th{
				color: #ffffff;
				border-right: 1px solid #ffffff;
				text-align: center;
				font-family: "microsoft yahei";
				font-size: 14px;
				line-height: 20px;
			}
			.tbody{
				width: 100%;
				border: 1px solid #007AFF;
			}
			.tbody tr{
				 width: 100%; 
				 height: 20px;
			}
			.tbody tr td{
				color: #000;
				border: 1px solid #007AFF;
				text-align: center;
				font-family: "microsoft yahei";
				font-size: 14px;
				line-height: 20px;
			}
			.div-tab{
				width: 100%; 
				height: 200px; 
				overflow-y: scroll;
			}
			.div-tab::-webkit-scrollbar {
				display: none;
			}
			.submit{
				margin:0 auto 10px auto; 
				width:200px; 
				height:35px; 
				line-height: 35px; 
				background-color:#007AFF; 
				text-align: center; 
				color: #FFFFFF; 
				border-radius: 10px;
			}
			.mui-ul-check{ width: 100%; margin: 0; padding: 0;}
			.mui-ul-check li{float: left; list-style-type:none; text-align: center; padding:5px; margin:2px; border:1px solid #D1D1D1;}
			.mui-ul-check li.on{ background-color:#007AFF; color:#FFFFFF; float: left; list-style-type:none; text-align: center; padding:5px; margin:2px;}
			.disable{color: #bbb;}
		</style>
	</head>
	<body>
		<header class="mui-bar mui-bar-nav">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 class="mui-title" id="high_id">产前随访</h1>
		</header>
		<div class="mui-conten" style="margin-top:50px;">
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">填表日期</div>
								<input id="result0" class="ui-alert"  placeholder="请选择" style="width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">孕周</div>
							<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align: right;">周</div>
							<input  id='Weeks_2' class="ui-alert border0" type="number" style="float: right; padding: 0 10px; width:50px; text-align: center; font-size: 12px;"/>
							<div style="float: right; font-size: 14px; width:10px; line-height: 26px; text-align: center;">+</div>
							<input  id='Weeks_1' class="ui-alert border0" type="number" style="float: right; padding: 0 10px; width:80px; text-align: center;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">所属胎次</div>
							<input  id='parity' class="ui-alert border0" type="number" style="float: right; width:50%;"/>
						</li>
					</div>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">丈夫姓名</div>
							<input  id='husband_name' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">丈夫年龄</div>
							<input  id='husband_age' class="ui-alert border0" type="number" style="float: right; width:50%;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">丈夫电话</div>
							<input  id='husband_tel' class="ui-alert border0" type="number" style="float: right; width:50%;"/>
						</li>
					</div>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">孕次</div>
							<input  id='attime' class="ui-alert border0" type="number" style="float: right; width:50%;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">孕妇年龄</div>
							<input  id='pregnantage' class="ui-alert border0" type="number" style="float: right; width:50%;"/>
						</li>
					</div>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">产次</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">阴道分娩</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='vaginal' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">刨宫产</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='abdomen' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">末次月经</div>
								<input id="result1" class="ui-alert"  placeholder="请选择" style="width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">预产期</div>
								<input id="result2" class="ui-alert"  placeholder="请选择" style="width:50%;"/>
							</a>
						</li>
					</div>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">既往史</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
						<ul class="mui-ul-check" id="ularry_1">
							<li value="56" id="wu-1">无</li>
							<li value="529">心脏病</li>
							<li value="530">肾脏疾病</li>
							<li value="531">肝脏疾病</li>
							<li value="43">高血压</li>
							<li value="532">贫血</li>
							<li value="44">糖尿病</li>
							<li value="482" text ="既往史其他">其他</li>
						</ul>
					</li>
					<li class="mui-table-view-cell" id="jws_id" style="display: none;">
						<input value="" id="jws" class="ui-alert bottom_soild"  placeholder="请输入其他" style="width:100%; float:right; margin-right:15px;"/>
					</li>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">家族史</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
						<ul class="mui-ul-check" id="ularry_2">
							<li value="56" id="wu-2">无</li>
							<li value="533">遗传性疾病</li>
							<li value="534">精神疾病史</li>
							<li value="482" text ="家族史其他">其他</li>
						</ul>
					</li>
					<li class="mui-table-view-cell" id="jzs_id" style="display: none;">
						<input value="" id="jzs" class="ui-alert bottom_soild"  placeholder="请输入其他" style="width:100%; float:right; margin-right:15px;"/>
					</li>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">个人史</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
						<ul class="mui-ul-check" id="ularry_3">
							<li value="56" id="wu-3">无特殊</li>
							<li value="76">吸烟</li>
							<li value="536">饮酒</li>
							<li value="537">服用药物</li>
							<li value="538">接触有毒有害物质</li>
							<li value="539">接触放射线</li>
							<li value="482" text ="个人史其他">其他</li>
						</ul>
					</li>
					<li class="mui-table-view-cell" id="grs_id" style="display: none;">
						<input value="" id="grs" class="ui-alert bottom_soild"  placeholder="请输入其他" style="width:100%; float:right; margin-right:15px;"/>
					</li>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
						<div style="float: left; font-size:16px;">妇科手术史</div>
						<div class="mui-switch new1" id="mySwitch4">
						  <div class="mui-switch-handle"></div>
						</div>
					</li>
					<li class="mui-table-view-cell" id="tigshow_doc_4" style="display: none;">
						<input class="ui-alert border0" id="doc_4"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
					</li>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">孕产史</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">1.自然流产</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_1' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">2.人工流产</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_2' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">3.死胎</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_3' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">4.死产</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_4' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">5.新生儿死亡</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_5' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}'>
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">6.出生缺陷儿</div>
								<div style="float: right; font-size: 14px; width: 20px; line-height: 26px; text-align:right;">次</div>
								<input  id='maternal_6' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							</a>
						</li>
					</div>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">身高</div>
							<div style="float: right; font-size: 14px; width: 50px; line-height: 26px; text-align:left;">cm</div>
							<input  id='cm' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">体重</div>
							<div style="float: right; font-size: 14px; width: 50px; line-height: 26px; text-align:left;">kg</div>
							<input  id='kg' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">体质指数</div>
							<div style="float: right; font-size: 14px; width: 50px; line-height: 26px; text-align:left;">Kg/㎡</div>
							<input  id='kgm' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">血压</div>
							<div style="float: right; font-size: 14px; width: 50px; line-height: 26px; text-align:left;">mmHg</div>
							<input  id='dbp' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
							<div style="float: right; line-height: 26px;">/</div>
							<input  id='sbp' class="ui-alert border0" type="number" style="float:right; width:80px; text-align:center;"/>
						</li>
					</div>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">听诊</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:16px;">心脏</div>
							<div class="mui-switch new2" id="mySwitch5">
							  <div class="mui-switch-handle"></div>
							</div>
						</li>
						<li class="mui-table-view-cell" id="tigshow_doc_5" style="display: none;">
							<input class="ui-alert border0" id="doc_5"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:16px;">肺部</div>
							<div class="mui-switch new2" id="mySwitch6">
							  <div class="mui-switch-handle"></div>
							</div>
						</li>
						<li class="mui-table-view-cell" id="tigshow_doc_6" style="display: none;">
							<input class="ui-alert border0" id="doc_6"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
						</li>
					</div>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">妇科检查</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:14px;">外阴</div>
							<div class="mui-switch new2" id="mySwitch7">
							  <div class="mui-switch-handle"></div>
							</div>
							<li class="mui-table-view-cell" id="tigshow_doc_7" style="display: none;">
						<input class="ui-alert border0" id="doc_7"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
							</li>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:14px;">阴道</div>
							<div class="mui-switch new2" id="mySwitch8">
							  <div class="mui-switch-handle"></div>
							</div>
							<li class="mui-table-view-cell" id="tigshow_doc_8" style="display: none;">
						<input class="ui-alert border0" id="doc_8"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
							</li>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:14px;">宫颈</div>
							<div class="mui-switch new2" id="mySwitch9">
							  <div class="mui-switch-handle"></div>
							</div>
							<li class="mui-table-view-cell" id="tigshow_doc_9" style="display: none;">
						<input class="ui-alert border0" id="doc_9"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
							</li>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:14px;">子宫</div>
							<div class="mui-switch new2" id="mySwitch10">
							  <div class="mui-switch-handle"></div>
							</div>
							<li class="mui-table-view-cell" id="tigshow_doc_10" style="display: none;">
						<input class="ui-alert border0" id="doc_10"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
							</li>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:14px;">附件</div>
							<div class="mui-switch new2" id="mySwitch11">
							  <div class="mui-switch-handle"></div>
							</div>
							<li class="mui-table-view-cell" id="tigshow_doc_11" style="display: none;">
						<input class="ui-alert border0" id="doc_11"  placeholder="请输入" style="float: left; width:100%; text-align: right; padding: 0 10px;"/>
							</li>
						</li>
					</div>
				</div>
			</ul>
			<div style="clear:both; font-size: 16px; line-height:25px; margin-left:15px; margin-top: 5px;">辅助检查</div>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="float: left; font-size: 14px; width:100%; line-height: 26px;">血常规</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">血红蛋白值</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">g/L</div>
								<input  id='blood_1' class="ui-alert border0"  placeholder="" style="float:right; width:100px;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">白细胞计数值</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">X10⁹/L</div>
								<input  id='blood_2' class="ui-alert border0"  placeholder="" style="float:right; width:100px;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">血小板计数值</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">X10⁹/L</div>
								<input  id='blood_3' class="ui-alert border0"  placeholder="" style="float:right; width:100px;"/>
							</div>
						</li>
						<li class="mui-table-view-cell" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">其他</div>
								<input  id='blood_4' class="ui-alert border0"  placeholder="" style="float:right; width:200px;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="float: left; font-size: 14px; width:50px; line-height: 26px;">尿常规</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">尿蛋白质</div>
								<input  id='urine_1' class="ui-alert border0"  placeholder="" style="float:right; width:60%;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">尿糖</div>
								<input  id='urine_2' class="ui-alert border0"  placeholder="" style="float:right; width:60%;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">尿酮体</div>
								<input  id='urine_3' class="ui-alert border0"  placeholder="" style="float:right; width:60%;"/>
							</div>
						</li>
						<li class="mui-table-view-cell-1" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">尿潜血</div>
								<input  id='urine_4' class="ui-alert border0"  placeholder="" style="float:right; width:60%;"/>
							</div>
						</li>
						<li class="mui-table-view-cell" style="padding: 5px 15px;">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">其他</div>
								<input  id='urine_5' class="ui-alert border0"  placeholder="" style="float:right; width:60%;"/>
							</div>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">血型</div>
								<input id="result3" class="ui-alert"  placeholder="请选择" style="width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">RH阴性</div>
								<input id="result4" class="ui-alert"  placeholder="请选择" style="width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<div style="width: 100%; clear: both;">
								<div style="float: left; font-size: 14px; width:90px; line-height: 26px;">血糖*</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">mmol/L</div>
								<input  id='sugar' class="ui-alert border0"  placeholder="" style="float:right; width:40%;"/>
							</div>
						</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:50px; line-height: 26px;">肝功能</div>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">血清谷丙转氨酶</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">U/L</div>
								<input  id='liver_1' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">血清谷草转氨酶</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">U/L</div>
								<input  id='liver_2' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">白蛋白</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">g/L</div>
								<input  id='liver_3' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">总胆红素</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">μmol/L</div>
								<input  id='liver_4' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell" style="padding: 5px 15px;">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">结合胆红素</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">μmol/L</div>
								<input  id='liver_5' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:50px; line-height: 26px;">肾功能</div>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">血清肌酐</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">μmol/L</div>
								<input  id='renal_1' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
							<li class="mui-table-view-cell" style="padding: 5px 15px;">
								<div style="float: left; font-size: 14px; width:120px; line-height: 26px;">血尿素</div>
								<div style="float: right; font-size: 14px; width:50px; line-height: 26px;">mmol/L</div>
								<input  id='renal_2' class="ui-alert border0"  placeholder="" style="float:right; width:90px; text-align: center;"/>
							</li>
						<li class="mui-table-view-cell">
								<div style="float: left; font-size: 14px; width:100%; line-height: 26px;">阴道分泌物*</div>
								<ul class="mui-ul-check" id="ularry_4">
									<li value="180" id="wu-4">未见异常</li>
									<li value="556">滴虫</li>
									<li value="557">假丝酵母菌</li>
									<li value="482" text="阴道分泌物其他">其他</li>
								</ul>
								<li class="mui-table-view-cell" id="fmw_id" style="display: none;">
									<input class="ui-alert border0" id="fmw"  placeholder="请输入" style="float: right; width:100%; text-align: right; padding: 0 10px;"/>
								</li>
								<li class="mui-table-view-cell">
									<a data-options='{"type":"date"}' class="btn mui-navigate-right">
										<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">阴道清洁度</div>
										<input id="result5" class="ui-alert"  placeholder="请选择" style="width:50%; float: right;"/>
									</a>
								</li>
						</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width:100%; line-height: 26px;">乙型肝炎五项</div>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">乙型肝炎表面抗原</div>
								<input  id='yliver_1' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">乙型肝炎表面抗体*</div>
								<input  id='yliver_2' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">乙型肝炎e抗原*</div>
								<input  id='yliver_3' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
							</li>
							<li class="mui-table-view-cell-1">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">乙型肝炎e抗体*</div>
								<input  id='yliver_4' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
							</li>
							<li class="mui-table-view-cell" style="padding: 5px 15px;">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">乙型肝炎核心抗体*</div>
								<input  id='yliver_5' class="ui-alert border0"  placeholder="" style="float: right; width:50%;"/>
							</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">梅毒血清学试验*</div>
								<input id="result6" class="ui-alert"  placeholder="请选择" style="float: right; width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 120px; line-height: 26px;">HIV抗体检测*</div>
								<input id="result7" class="ui-alert"  placeholder="请选择" style="float: right; width:50%;"/>
							</a>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 40px; line-height: 26px;">B超*</div>
							<input class="ui-alert border0" id="Bchao"  placeholder="请输入" style="float: right; width:70%; text-align: right; padding: 0 10px;"/>
						</li>
						<li class="mui-table-view-cell">
							<div style="float: left; font-size: 14px; width: 40px; line-height: 26px;">其他*</div>
							<input class="ui-alert border0" id="fuzhuother"  placeholder="请输入" style="float: right; width:70%; text-align: right; padding: 0 10px;"/>
						</li>
					</div>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<li class="mui-table-view-cell">
					<div style="float: left; font-size:14px;">总体评估</div>
					<div class="mui-switch new2" id="mySwitch12">
					  <div class="mui-switch-handle"></div>
					</div>
					<li class="mui-table-view-cell" id="tigshow_doc_12" style="display: none;">
						<input class="ui-alert border0" id="doc_12"  placeholder="请输入" style="float: right; width:100%; text-align: right; padding: 0 10px;"/>
					</li>
				</li>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<div style="float: left; font-size: 14px; width: 90px; width: 100%; padding-left:15px;">保健指导</div>
					<li class="mui-table-view-cell">
						<ul class="mui-ul-check" id="ularry_5">
							<li value="605">生活方式</li>
							<li value="541">心理</li>
							<li value="542">营养</li>
							<li value="544">产前筛查宣传告知</li>
							<li value="543">避免致畸形因素和疾病对胚胎的不良影响</li>
							<li value="482" text="保健指导其他">其他</li>
						</ul>
					</li>
					<li class="mui-table-view-cell" id="bjzd_id" style="display: none;">
						<input class="ui-alert border0" id="bjzd"  placeholder="请输入" style="float: right; width:100%; text-align: right; padding: 0 10px;"/>
					</li>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
						<div style="float: left; font-size:14px;">转诊</div>
						<div class="mui-switch new1" id="mySwitch13">
						  <div class="mui-switch-handle"></div>
						</div>
						<li class="mui-table-view-cell" id="chuli" style="display: none;">
							<div style="float: left; width:100%;">
								<div style="float: left; font-size: 16px; width:50px; text-align:center;">原因:</div>
								<input id='chuli_why' class="ui-alert bottom_soild"  placeholder="请输入" style="width:60%; margin-left: 6px;"/>
							</div>
							<div style="float: left; width:100%;">
								<div style="float: left; font-size: 16px; width:90px; text-align:center;">机构及科室:</div>
								<input id='chuli_det' class="ui-alert bottom_soild"  placeholder="请输入" style="width:60%; margin-left: 6px;"/>
							</div>
						</li>
					</li>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-col-sm-12 mui-col-xs-12">
					<li class="mui-table-view-cell">
					<div style="float: left; font-size: 14px; width: 40px; line-height: 26px;">备注</div>
						<input class="ui-alert border0" id="note"  placeholder="请输入" style="float: right; width:70%; text-align: right; padding: 0 10px;"/>
					</li>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<div style="float: left; font-size: 14px; width: 90px; line-height: 26px;">下次随访日期</div>
								<input  id='result8' name="Fill_date" class="ui-alert"  placeholder="请选择" style="float: right; width:50%;"/>
							</a>
						</li>
					</div>
				</div>
			</ul>
			<ul class="mui-table-view" style="margin-top: 5px;">
				<div class="mui-row">
					<div class="mui-col-sm-12 mui-col-xs-12">
						<li class="mui-table-view-cell">
							<div style="float: left; font-size:16px;">医生签名</div>
							<div class="mui-switch" id="mySwitch3">
							  <div class="mui-switch-handle"></div>
							</div>
						</li>
						<li class="mui-table-view-cell" id="tigshow_doc_1">
							<a data-options='{"type":"date"}' class="btn mui-navigate-right">
								<input id='result9' class="ui-alert"  placeholder="请选择" style="width:50%; text-align: right; float: right; padding-right: 15px;"/>
							</a>
						</li>
						<li class="mui-table-view-cell" style="display: none;" id="tigshow_doc_2">
							<div style="float: left; width:100%;">
								<div style="float: left; font-size: 16px; width:5rem; text-align:center;">医院</div>
								<input id='text-doc' class="ui-alert bottom_soild"  placeholder="请输入" style="width:60%; margin-left: 6px;"/>
							</div>
							<div style="float: left; width:100%;">
								<div style="float: left; font-size: 16px; width:5rem; text-align:center;">医生</div>
								<input id='text-hosp' class="ui-alert bottom_soild"  placeholder="请输入" style="width:60%; margin-left: 6px;"/>
							</div>
						</li>
					</div>
				</div>
			</ul>
			<ul style="padding:10px 15px; margin: 0;">
				<p style="color: red; margin: 0;">
					提示：
					</br>
					若随方医生是省外的，则使用“填写”方式，手工输入随方医生信息。
					</br>
					若随方医生是省内的，则使用“选择”方式，选择对应医院和随方医生。
				</p>
			</ul>
			<div onclick="submit()" class="submit" >提交</div>
		</div>
		<script src="../../js/mui.js"></script>
		<script src="../../js/mui.picker.min.js"></script>
		<script src="../../js/jquery.min-1.11.1.js"></script>
		<script src="../../js/request.js"></script>
		<script type="text/javascript">
			var resultall = {"r1":[{value:'0',text:' '},{value:'3',text:'A型'},{value:'4',text:'B型'},{value:'5',text:'O型'},{value:'6',text:'AB型'},{value:'16',text:'不详'}],
			 				"r2":[{value:'0',text:' '},{value:'9',text:'否'},{value:'8',text:'是'},{value:'16',text:'不详'}],
			 				"r3":[{value:'0',text:' '},{value:'558',text:'Ⅰ度'},{value:'559',text:'Ⅱ度'},{value:'560',text:'Ⅲ度'},{value:'561',text:'Ⅳ度'}],
			 				"r4":[{value:'0',text:' '},{value:'185',text:'阴性'},{value:'186',text:'阳性'}]}
			var id = 0,
				ehrId = "",
				parity = "",//胎次
				visitLevel = 1,//1、产前第一次随访 2、产前2-5次随访 3、产后随访 4、产后24天随访
				visitDate = "",//随访时间
				nextDate = "",
				doctorName = "",
				visitItem = 0,
				gestationalWeeks = 0,
				createUser = "",
				updateUser = "",
				createDate = "",
				updateDate = "",
				enableFlag = 1,
				doctorId = "",
				doctorHospId = "",
				doctorHospName = "",
				xkSign = null,
				ipOutDate = "",
				childbirthDate = "",
				versionNum = 2018,
				ifVisit = 0,
				readcardCheck = 2;
			var listdata = "";
			var selfdata = "";
			var result0 = "",
				result1 = "",
				result2 = "",
				result3 = "0",
				result4 = "0",
				result5 = "0",
				result6 = "0",
				result7 = "0",
				result8 = "",
				dated,
				dateov;
			var newdate = new Date();
			var self1 = localStorage.getItem("name")
			var dataself = JSON.parse(self1)
			console.log(dataself)
			doctorName = dataself.obj.userName;//责任(评估)医生名字
			doctorId = dataself.obj.id;//责任(评估)医生id
			doctorHospId = dataself.obj.hospId;//责任(评估)医生医院id
			createHospId = dataself.obj.hospId;//创建医院id
			doctorHospName = dataself.obj.hospName;//责任(评估)医生医院名称
			document.getElementById("result9").value = dataself.obj.userName;//前台显示
			mui.plusReady(function(){
				var self = plus.webview.currentWebview()
					listdata = self.data
					selfdata = JSON.parse(listdata)
					console.log(JSON.stringify(selfdata))
					//赋值
				var date1 = new Date();
				var year1=date1.getFullYear(); 
				var month1=date1.getMonth()+1;
				var day1=date1.getDate();
				var h1=date1.getHours();
				var m1=date1.getMinutes();
				var s1=date1.getSeconds();
					month1 =(month1<10 ? "0"+month1:month1); 
					day1 =(day1<10 ? "0"+day1:day1); 
					h1 =(h1<10 ? "0"+h1:h1); 
					m1 =(m1<10 ? "0"+m1:m1); 
					s1 =(s1<10 ? "0"+s1:s1);
				var newDate = (year1.toString()+'-'+month1.toString()+'-'+day1.toString()+' '+h1.toString()+':'+m1.toString()+':'+s1.toString())
					ehrId = selfdata.ehrId
					if(selfdata.id != undefined){
						id = selfdata.id;
						document.getElementById("parity").value = selfdata.parity;
						document.getElementById("Weeks_1").value = selfdata.gestationalWeeks;
						if(selfdata.visitDate != ""){//随访日期
							var datev = new Date(selfdata.visitDate);
							var yearv=datev.getFullYear(); 
							var monthv=datev.getMonth()+1;
							var dayv=datev.getDate();
								monthv =(monthv<10 ? "0"+monthv:monthv); 
								dayv =(dayv<10 ? "0"+dayv:dayv); 
							var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
							document.getElementById("result0").value = datab;
						}else{
							document.getElementById("result0").value = "";
						}
						if(selfdata.nextDate != ""){//下次随访日期
							var datev = new Date(selfdata.nextDate);
							var yearv=datev.getFullYear(); 
							var monthv=datev.getMonth()+1;
							var dayv=datev.getDate();
								monthv =(monthv<10 ? "0"+monthv:monthv); 
								dayv =(dayv<10 ? "0"+dayv:dayv); 
							var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
							document.getElementById("result8").value = datab;
						}else{
							document.getElementById("result8").value = "";
						}
						doctorName = selfdata.doctorName;
						visitItem = selfdata.visitItem;
						createUser = selfdata.createUser;
						updateUser = selfdata.updateUser;
						createDate = selfdata.createDate;
						updateDate = selfdata.updateDate;
						doctorId = selfdata.doctorId;
						doctorHospId = selfdata.doctorHospId;
						doctorHospName = selfdata.doctorHospName;
						if(selfdata.ipOutDate != ""){//出院日期
							var datev = new Date(selfdata.ipOutDate);
							var yearv=datev.getFullYear(); 
							var monthv=datev.getMonth()+1;
							var dayv=datev.getDate();
								monthv =(monthv<10 ? "0"+monthv:monthv); 
								dayv =(dayv<10 ? "0"+dayv:dayv); 
							var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
							document.getElementById("result2").value = datab;
						}else{
							document.getElementById("result2").value = "";
						}
						if(selfdata.childbirthDate != ""){//分娩日期
							var datev = new Date(selfdata.childbirthDate);
							var yearv=datev.getFullYear(); 
							var monthv=datev.getMonth()+1;
							var dayv=datev.getDate();
								monthv =(monthv<10 ? "0"+monthv:monthv); 
								dayv =(dayv<10 ? "0"+dayv:dayv); 
							var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
							document.getElementById("result1").value = datab;
						}else{
							document.getElementById("result1").value = "";
						}
						console.log(id)
						mui.ajax(getRequestUrl.url+'/mobile/ehr/maternalHealthAnswer/getVisitDetail',{
							data:{
								"m_id":id,
								"ehr_id":ehrId
							},
							dataType:'json',//服务器返回json格式数据
							type:'post',//HTTP请求类型
							timeout:10000,//超时时间设置为10秒；
							success:function(data){
								console.log("获取成功")
								var rows = data.rows;
								if (data.status == 1) {
									for(var i=0; i<rows.length; i++){
										if(rows[i].questionId == "707"){//孕周+
											document.getElementById("Weeks_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "601"){//丈夫名
											document.getElementById("husband_name").value = rows[i].answer;
										}
										if(rows[i].questionId == "602"){//丈夫年龄
											document.getElementById("husband_age").value = rows[i].answer;
										}
										if(rows[i].questionId == "603"){//丈夫电话
											document.getElementById("husband_tel").value = rows[i].answer;
										}
										if(rows[i].questionId == "585"){//孕次
											document.getElementById("attime").value = rows[i].answer;
										}
										if(rows[i].questionId == "600"){//孕妇年龄
											document.getElementById("pregnantage").value = rows[i].answer;
										}
										if(rows[i].questionId == "605"){//阴道分娩
											document.getElementById("vaginal").value = rows[i].answer;
										}
										if(rows[i].questionId == "606"){//刨宫产
											document.getElementById("abdomen").value = rows[i].answer;
										}
										if(rows[i].questionId == "607"){//末次月经
											if(rows[i].answer != ""){
												var datev = new Date(rows[i].answer);
												var yearv=datev.getFullYear(); 
												var monthv=datev.getMonth()+1;
												var dayv=datev.getDate();
													monthv =(monthv<10 ? "0"+monthv:monthv); 
													dayv =(dayv<10 ? "0"+dayv:dayv); 
												var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
												document.getElementById("result1").value = datab;
											}else{
												document.getElementById("result1").value = "";
											}
										}
										if(rows[i].questionId == "608"){//预产期
											if(rows[i].answer != ""){
												var datev = new Date(rows[i].answer);
												var yearv=datev.getFullYear(); 
												var monthv=datev.getMonth()+1;
												var dayv=datev.getDate();
													monthv =(monthv<10 ? "0"+monthv:monthv); 
													dayv =(dayv<10 ? "0"+dayv:dayv); 
												var datab = (yearv.toString()+'-'+monthv.toString()+'-'+dayv.toString());
												document.getElementById("result2").value = datab;
											}else{
												document.getElementById("result2").value = "";
											}
										}
										if(rows[i].questionId == "588"){//既往史
											var select1Ynarr = rows[i].answer;
											if(select1Ynarr != null){
												var select1Ynarr_n = select1Ynarr.split(",");
												if(select1Ynarr_n.length != 0){
													$ ("#ularry_1").each (function (){
														$ (this).find ('li').each (function (){
															var y = select1Ynarr_n.length-1;
															for (var i=0; i<select1Ynarr_n.length; i++) {
																if ($(this).val() == select1Ynarr_n[i]) {
											                        $(this).addClass("on");
																	if(select1Ynarr_n[y] == "56"){
																		$("#jws_id").hide();
																		$("#jws").val("");
																		$("#wu-1").siblings().addClass("disable");
																	}else if(select1Ynarr_n[y] == "482"){
																		document.getElementById("jws_id").style.display="block";
																	}else{
																		document.getElementById("jws_id").style.display="none";
																	}
											                    }		
															}
														})
													})	
												}
											}
										}
										if(rows[i].questionId == "657"){
											document.getElementById("jws").value = rows[i].answer;
										}
										if(rows[i].questionId == "589"){//家族史
											var select2Ynarr = rows[i].answer;
											if(select2Ynarr != null){
												var select2Ynarr_n = select2Ynarr.split(",");
												if(select2Ynarr_n.length != 0){
													$ ("#ularry_2").each (function (){
														$ (this).find ('li').each (function (){
															var y = select2Ynarr_n.length-1;
															for (var i=0; i<select2Ynarr_n.length; i++) {
																if ($(this).val() == select2Ynarr_n[i]) {
											                        $(this).addClass("on");
																	if(select1Ynarr_n[y] == "56"){
																		$("#jzs_id").hide();
																		$("#jzs").val("");
																		$("#wu-2").siblings().addClass("disable");
																	}else if(select2Ynarr_n[y] == "482"){
																		document.getElementById("jzs_id").style.display="block";
																	}else{
																		document.getElementById("jzs_id").style.display="none";
																	}
											                    }		
															}
														})
													})	
												}
											}
										}
										if(rows[i].questionId == "658"){
											document.getElementById("jzs").value = rows[i].answer;
										}
										if(rows[i].questionId == "609"){//个人史
											var select3Ynarr = rows[i].answer;
											if(select3Ynarr != null){
												var select3Ynarr_n = select3Ynarr.split(",");
												if(select3Ynarr_n.length != 0){
													$ ("#ularry_3").each (function (){
														$ (this).find ('li').each (function (){
															var y = select3Ynarr_n.length-1;
															for (var i=0; i<select3Ynarr_n.length; i++) {
																if ($(this).val() == select3Ynarr_n[i]) {
											                        $(this).addClass("on");
																	if(select1Ynarr_n[y] == "56"){
																		$("#grs_id").hide();
																		$("#grs").val("");
																		$("#wu-3").siblings().addClass("disable");
																	}else if(select3Ynarr_n[y] == "482"){
																		document.getElementById("grs_id").style.display="block";
																	}else{
																		document.getElementById("grs_id").style.display="none";
																	}
											                    }		
															}
														})
													})	
												}
											}
										}
										if(rows[i].questionId == "659"){
											document.getElementById("grs").value = rows[i].answer;
										}
										if(rows[i].questionId == "610"){//妇科手术史
											if(rows[i].answerId != "180"){
												mySwitch4 = "181"
												document.getElementById("tigshow_doc_4").style.display = "block";
												document.getElementById("mySwitch4").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_4").style.display = "none";
												document.getElementById("mySwitch4").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "612"){//妇科手术史1
											document.getElementById("doc_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "614"){//自然流产
											document.getElementById("maternal_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "704"){//人工流产
											document.getElementById("maternal_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "615"){//死胎
											document.getElementById("maternal_3").value = rows[i].answer;
										}
										if(rows[i].questionId == "616"){//死产
											document.getElementById("maternal_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "617"){//新生儿死亡
											document.getElementById("maternal_5").value = rows[i].answer;
										}
										if(rows[i].questionId == "618"){//出生缺陷儿
											document.getElementById("maternal_6").value = rows[i].answer;
										}
										if(rows[i].questionId == "88"){//身高
											document.getElementById("cm").value = rows[i].answer;
										}
										if(rows[i].questionId == "89"){//体重
											document.getElementById("kg").value = rows[i].answer;
										}
										if(rows[i].questionId == "91"){//体质
											document.getElementById("kgm").value = rows[i].answer;
										}
										if(rows[i].questionId == "85"){//血压1
											document.getElementById("sbp").value = rows[i].answer;
										}
										if(rows[i].questionId == "86"){//血压2
											document.getElementById("dbp").value = rows[i].answer;
										}
										if(rows[i].questionId == "620"){//心脏
											if(rows[i].answerId != "180"){
												mySwitch5 = "181"
												document.getElementById("tigshow_doc_5").style.display = "block";
												document.getElementById("mySwitch5").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_5").style.display = "none";
												document.getElementById("mySwitch5").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "621"){//心脏1
											document.getElementById("doc_5").value = rows[i].answer;
										}
										if(rows[i].questionId == "622"){//肺部
											if(rows[i].answerId != "180"){
												mySwitch6 = "181"
												document.getElementById("tigshow_doc_6").style.display = "block";
												document.getElementById("mySwitch6").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_6").style.display = "none";
												document.getElementById("mySwitch6").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "623"){//肺部1
											document.getElementById("doc_6").value = rows[i].answer;
										}
										if(rows[i].questionId == "141"){//外阴
											if(rows[i].answerId != "180"){
												mySwitch7 = "181"
												document.getElementById("tigshow_doc_7").style.display = "block";
												document.getElementById("mySwitch7").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_7").style.display = "none";
												document.getElementById("mySwitch7").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "142"){//外阴1
											document.getElementById("doc_7").value = rows[i].answer;
										}
										if(rows[i].questionId == "143"){//阴道
											if(rows[i].answerId != "180"){
												mySwitch8 = "181"
												document.getElementById("tigshow_doc_8").style.display = "block";
												document.getElementById("mySwitch8").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_8").style.display = "none";
												document.getElementById("mySwitch8").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "144"){//阴道1
											document.getElementById("doc_8").value = rows[i].answer;
										}
										if(rows[i].questionId == "145"){//宫颈
											if(rows[i].answerId != "180"){
												mySwitch9 = "181"
												document.getElementById("tigshow_doc_9").style.display = "block";
												document.getElementById("mySwitch9").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_9").style.display = "none";
												document.getElementById("mySwitch9").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "146"){//宫颈1
											document.getElementById("doc_9").value = rows[i].answer;
										}
										if(rows[i].questionId == "147"){//子宫
											if(rows[i].answerId != "180"){
												mySwitch10 = "181"
												document.getElementById("tigshow_doc_10").style.display = "block";
												document.getElementById("mySwitch10").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_10").style.display = "none";
												document.getElementById("mySwitch10").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "148"){//子宫1
											document.getElementById("doc_10").value = rows[i].answer;
										}
										if(rows[i].questionId == "149"){//附件
											if(rows[i].answerId != "180"){
												mySwitch11 = "181"
												document.getElementById("tigshow_doc_11").style.display = "block";
												document.getElementById("mySwitch11").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_11").style.display = "none";
												document.getElementById("mySwitch11").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "150"){//附件1
											document.getElementById("doc_11").value = rows[i].answer;
										}
										if(rows[i].questionId == "161"){//血红蛋白值
											document.getElementById("blood_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "162"){//白细胞计数值
											document.getElementById("blood_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "163"){//血小板计数值
											document.getElementById("blood_3").value = rows[i].answer;
										}
										if(rows[i].questionId == "164"){//其他
											document.getElementById("blood_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "165"){//尿蛋白
											document.getElementById("urine_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "166"){//尿糖
											document.getElementById("urine_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "167"){//尿酮体
											document.getElementById("urine_3").value = rows[i].answer;
										}
										if(rows[i].questionId == "168"){//尿潜血
											document.getElementById("urine_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "169"){//其它
											document.getElementById("urine_5").value = rows[i].answer;
										}
										if(rows[i].questionId == "13"){//血型
											var rowsresult3=resultall.r1;
											for (var j=0; j<rowsresult3.length; j++) {
												if(rows[i].answerId == rowsresult3[j].value){
													document.getElementById("result3").value = rowsresult3[j].text;
												}
											}
										}
										if(rows[i].questionId == "26"){//RH
											var rowsresult4=resultall.r2;
											for (var j=0; j<rowsresult4.length; j++) {
												if(rows[i].answerId == rowsresult4[j].value){
													document.getElementById("result4").value = rowsresult4[j].text;
												}
											}
										}
										if(rows[i].questionId == "160"){//血糖
											document.getElementById("sugar").value = rows[i].answer;
										}
										if(rows[i].questionId == "172"){//肝功能1
											document.getElementById("liver_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "173"){//肝功能2
											document.getElementById("liver_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "174"){//肝功能3
											document.getElementById("liver_3").value = rows[i].answer;
										}
										if(rows[i].questionId == "175"){//肝功能4
											document.getElementById("liver_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "176"){//肝功能5
											document.getElementById("liver_5").value = rows[i].answer;
										}
										if(rows[i].questionId == "177"){//肾功能1
											document.getElementById("renal_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "178"){//肾功能2
											document.getElementById("renal_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "626"){//阴道分泌物
											var select4Ynarr = rows[i].answer;
											if(select3Ynarr != null){
												var select4Ynarr_n = select4Ynarr.split(",");
												if(select4Ynarr_n.length != 0){
													$ ("#ularry_4").each (function (){
														$ (this).find ('li').each (function (){
															var y = select4Ynarr_n.length-1;
															for (var i=0; i<select4Ynarr_n.length; i++) {
																if ($(this).val() == select4Ynarr_n[i]) {
											                        $(this).addClass("on");
																	if(select4Ynarr_n[y] == "180"){
																		$("#fmw_id").hide();
																		$("#fmw").val("");
																		$("#wu-4").siblings().addClass("disable");
																	}else if(select4Ynarr_n[y] == "482"){
																		document.getElementById("fmw_id").style.display="block";
																	}else{
																		document.getElementById("fmw_id").style.display="none";
																	}
											                    }		
															}
														})
													})	
												}
											}
										}
										if(rows[i].questionId == "627"){//阴道分泌物其它
											document.getElementById("fmw").value = rows[i].answer;
										}
										if(rows[i].questionId == "628"){//阴道清洁度
											var rowsresult5=resultall.r3;
											for (var j=0; j<rowsresult5.length; j++) {
												if(rows[i].answerId == rowsresult5[j].value){
													document.getElementById("result5").value = rowsresult5[j].text;
												}
											}
										}
										if(rows[i].questionId == "629"){//乙肝1
											document.getElementById("yliver_1").value = rows[i].answer;
										}
										if(rows[i].questionId == "630"){//乙肝2
											document.getElementById("yliver_2").value = rows[i].answer;
										}
										if(rows[i].questionId == "631"){//乙肝3
											document.getElementById("yliver_3").value = rows[i].answer;
										}
										if(rows[i].questionId == "632"){//乙肝4
											document.getElementById("yliver_4").value = rows[i].answer;
										}
										if(rows[i].questionId == "633"){//乙肝5
											document.getElementById("yliver_5").value = rows[i].answer;
										}
										if(rows[i].questionId == "634"){//梅毒血清
											var rowsresult6=resultall.r4;
											for (var j=0; j<rowsresult6.length; j++) {
												if(rows[i].answerId == rowsresult6[j].value){
													document.getElementById("result6").value = rowsresult6[j].text;
												}
											}
										}
										if(rows[i].questionId == "635"){//HIV抗体
											var rowsresult7=resultall.r4;
											for (var j=0; j<rowsresult7.length; j++) {
												if(rows[i].answerId == rowsresult7[j].value){
													document.getElementById("result7").value = rowsresult7[j].text;
												}
											}
										}
										if(rows[i].questionId == "194"){//B超
											document.getElementById("Bchao").value = rows[i].answer;
										}
										if(rows[i].questionId == "440"){//其它
											document.getElementById("fuzhuother").value = rows[i].answer;
										}
										if(rows[i].questionId == "636"){//总体评估
											if(rows[i].answerId != "180"){
												mySwitch12 = "181"
												document.getElementById("tigshow_doc_12").style.display = "block";
												document.getElementById("mySwitch12").classList.add('mui-active');
											}else{
												document.getElementById("tigshow_doc_12").style.display = "none";
												document.getElementById("mySwitch12").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "637"){//总体评估1
											document.getElementById("doc_12").value = rows[i].answer;
										}
										if(rows[i].questionId == "638"){//保健指导
											var select5Ynarr = rows[i].answer;
											if(select5Ynarr != null){
												var select5Ynarr_n = select5Ynarr.split(",");
												if(select5Ynarr_n.length != 0){
													$ ("#ularry_1").each (function (){
														$ (this).find ('li').each (function (){
															var y = select5Ynarr_n.length-1;
															for (var i=0; i<select5Ynarr_n.length; i++) {
																if ($(this).val() == select5Ynarr_n[i]) {
											                        $(this).addClass("on");
																	if(select5Ynarr_n[y] == "482"){
																		document.getElementById("bjzd_id").style.display="block";
																	}else{
																		document.getElementById("bjzd_id").style.display="none";
																	}
											                    }		
															}
														})
													})	
												}
											}
										}
										if(rows[i].questionId == "587"){//保健指导其它
											document.getElementById("bjzd").value = rows[i].answer;
										}
										if(rows[i].questionId == "332"){//转诊
											if(rows[i].answerId != "56"){
												mySwitch13 = "55"
												document.getElementById("chuli").style.display = "block";
												document.getElementById("mySwitch13").classList.add('mui-active');
											}else{
												document.getElementById("chuli").style.display = "none";
												document.getElementById("mySwitch13").classList.remove('mui-active');
											}
										}
										if(rows[i].questionId == "333"){//原因
											document.getElementById("chuli_why").value = rows[i].answer;
										}
										if(rows[i].questionId == "334"){//科室
											document.getElementById("chuli_det").value = rows[i].answer;
										}
										if(rows[i].questionId == "584"){//备注
											document.getElementById("note").value = rows[i].answer;
										}
										
										
									}
								} else {
									
								}
							},
							error:function(xhr,type,errorThrown){
								
							}
						});	
					}else{
						visitDate = newDate;//随访时间
						doctorName = dataself.obj.userName;
						createUser = dataself.obj.id;
						updateUser = dataself.obj.id;
						createDate = newDate;
						updateDate = newDate;
						doctorId = dataself.obj.id;
						doctorHospId = dataself.obj.hospId;
						doctorHospName = dataself.obj.hospName;
					};
			});	
			//内容字段部分
			mui.init()
				(function($) {
				$.init();
				var result = $('#result')[0];
				var btns = $('.btn');
				btns.each(function(i, btn) {
					btn.addEventListener('tap', function() {
						var _self = this;
						if(_self.picker) {
							_self.picker.show(function (rs) {
								result.innerText = rs.text;
								_self.picker.dispose();
								_self.picker = null;
							});
						} else {
							//alert(i)
							if(i == 3){
								var picker = new mui.PopPicker();
								 picker.setData([{value:'0',text:' '},{value:'3',text:'A型'},{value:'4',text:'B型'},{value:'5',text:'O型'},{value:'6',text:'AB型'},{value:'16',text:'不详'}]);
								 picker.show(function (selectItems) {
									 $('#result'+i)[0].value = selectItems[0].text;
								  })
							}else if(i == 4){
								var picker = new mui.PopPicker();
								 picker.setData([{value:'0',text:' '},{value:'9',text:'否'},{value:'8',text:'是'},{value:'16',text:'不详'}]);
								 picker.show(function (selectItems) {
									 $('#result'+i)[0].value = selectItems[0].text;
								  })
							}else if(i == 5){
								var picker = new mui.PopPicker();
								 picker.setData([{value:'0',text:' '},{value:'558',text:'Ⅰ度'},{value:'559',text:'Ⅱ度'},{value:'560',text:'Ⅲ度'},{value:'561',text:'Ⅳ度'}]);
								 picker.show(function (selectItems) {
									 $('#result'+i)[0].value = selectItems[0].text;
								  })
							}else if(i == 6){
								var picker = new mui.PopPicker();
								 picker.setData([{value:'0',text:' '},{value:'185',text:'阴性'},{value:'186',text:'阳性'}]);
								 picker.show(function (selectItems) {
									 $('#result'+i)[0].value = selectItems[0].text;
								  })
							}else if(i == 7){
								var picker = new mui.PopPicker();
								 picker.setData([{value:'0',text:' '},{value:'185',text:'阴性'},{value:'186',text:'阳性'}]);
								 picker.show(function (selectItems) {
									 $('#result'+i)[0].value = selectItems[0].text;
								  })
							}else{
								var optionsJson = this.getAttribute('data-options') || '{}';
								var options = JSON.parse(optionsJson);
								var id = this.getAttribute('id');
								/*
								 * 首次显示时实例化组件
								 * 示例为了简洁，将 options 放在了按钮的 dom 上
								 * 也可以直接通过代码声明 optinos 用于实例化 DtPicker
								 */
								_self.picker = new $.DtPicker(options);
								_self.picker.show(function(rs) {
									/*
									 * rs.value 拼合后的 value
									 * rs.text 拼合后的 text
									 * rs.y 年，可以通过 rs.y.vaue 和 rs.y.text 获取值和文本
									 * rs.m 月，用法同年
									 * rs.d 日，用法同年
									 * rs.h 时，用法同年
									 * rs.i 分（minutes 的第二个字母），用法同年
									 */
									$('#result'+i)[0].value = rs.text;
									/* 
									 * 返回 false 可以阻止选择框的关闭
									 * return false;
									 */
									/*
									 * 释放组件资源，释放后将将不能再操作组件
									 * 通常情况下，不需要示放组件，new DtPicker(options) 后，可以一直使用。
									 * 当前示例，因为内容较多，如不进行资原释放，在某些设备上会较慢。
									 * 所以每次用完便立即调用 dispose 进行释放，下次用时再创建新实例。
									 */
									_self.picker.dispose();
									_self.picker = null;
								});
							}
						}
					}, false);
				});
			})(mui);
			//切换
			document.getElementById("mySwitch3").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_1").style.display="none";
					document.getElementById("tigshow_doc_2").style.display="block";
					doctorHospId = "0";//签名医生医院id
					doctorHospName = document.getElementById("text-hosp").value;//签名医生医院名字
					doctorId = "0";//签名医生id
					doctorName = document.getElementById("text-doc").value;//签名医生姓名
				}else{
					document.getElementById("tigshow_doc_1").style.display="block";
					document.getElementById("tigshow_doc_2").style.display="none";
					if(doctorId == ""){
						doctorHospId = "";//签名医生医院id
						doctorHospName = "";//签名医生医院名字
						doctorId = "";//签名医生id
						doctorName = "";//签名医生姓名
					}
				}
			})
			//切换
			var mySwitch4 = "56",
				mySwitch5 = "180",
				mySwitch6 = "180",
				mySwitch7 = "180",
				mySwitch8 = "180",
				mySwitch9 = "180",
				mySwitch10 = "180",
				mySwitch11 = "180",
				mySwitch12 = "180",
				mySwitch13 = "56";
			document.getElementById("mySwitch4").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_4").style.display="block";
					mySwitch4 = "55";
				}else{
					document.getElementById("tigshow_doc_4").style.display="none";
					mySwitch4 = "56";
					$("#doc_4").val("");
				}
			})
			document.getElementById("mySwitch5").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_5").style.display="block";
					mySwitch5 = "181";
				}else{
					document.getElementById("tigshow_doc_5").style.display="none";
					mySwitch5 = "180";
					$("#doc_5").val("");
				}
			})
			document.getElementById("mySwitch6").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_6").style.display="block";
					mySwitch6 = "181";
				}else{
					document.getElementById("tigshow_doc_6").style.display="none";
					mySwitch6 = "180";
					$("#doc_6").val("");
				}
			})
			document.getElementById("mySwitch7").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_7").style.display="block";
					mySwitch7 = "181";
				}else{
					document.getElementById("tigshow_doc_7").style.display="none";
					mySwitch7 = "180";
					$("#doc_7").val("");
				}
			})
			document.getElementById("mySwitch8").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_8").style.display="block";
					mySwitch8 = "181";
				}else{
					document.getElementById("tigshow_doc_8").style.display="none";
					mySwitch8 = "180";
					$("#doc_8").val("");
				}
			})
			document.getElementById("mySwitch9").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_9").style.display="block";
					mySwitch9 = "181";
				}else{
					document.getElementById("tigshow_doc_9").style.display="none";
					mySwitch9 = "180";
					$("#doc_9").val("");
				}
			})
			document.getElementById("mySwitch10").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_10").style.display="block";
					mySwitch10 = "181";
				}else{
					document.getElementById("tigshow_doc_10").style.display="none";
					mySwitch10 = "180";
					$("#doc_10").val("");
				}
			})
			document.getElementById("mySwitch11").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_11").style.display="block";
					mySwitch11 = "181";
				}else{
					document.getElementById("tigshow_doc_11").style.display="none";
					mySwitch11 = "180";
					$("#doc_11").val("");
				}
			})
			document.getElementById("mySwitch12").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_12").style.display="block";
					mySwitch12 = "181";
				}else{
					document.getElementById("tigshow_doc_12").style.display="none";
					mySwitch12 = "180";
					$("#doc_12").val("");
				}
			})
			document.getElementById("mySwitch13").addEventListener("toggle",function(event){
				if(event.detail.isActive){
					document.getElementById("tigshow_doc_13").style.display="block";
					mySwitch13 = "181";
				}else{
					document.getElementById("tigshow_doc_13").style.display="none";
					mySwitch13 = "180";
					$("#chuli_why").val("");
					$("#chuli_det").val("");
				}
			})
			//复选框事件
			mui('.mui-ul-check').on('tap', 'li', function(e) {
				var text = this.getAttribute('text');
				var id = this.getAttribute('id');
				var remove_class = this.getAttribute('class');
				if(!this.getAttribute('class')){
					this.classList.add('on');
					if(id == "wu-1"){
						$ ("#ularry_1").find ('.on').each (function (){
							this.classList.remove('on');
							$("#jws_id").hide();
							$("#jws").val("");
							$("#wu-1").siblings().addClass("disable");
							$("#wu-1")[0].classList.add('on');
						});
					}else if(id == "wu-2"){
						$ ("#ularry_2").find ('.on').each (function (){
							this.classList.remove('on');
							$("#jzs_id").hide();
							$("#jzs").val("");
							$("#wu-2").siblings().addClass("disable");
							$("#wu-2")[0].classList.add('on');
						});
					}else if(id == "wu-3"){
						$ ("#ularry_3").find ('.on').each (function (){
							this.classList.remove('on');
							$("#grs_id").hide();
							$("#grs").val("");
							$("#wu-3").siblings().addClass("disable");
							$("#wu-3")[0].classList.add('on');
						});
					}else if(id == "wu-4"){
						$ ("#ularry_4").find ('.on').each (function (){
							this.classList.remove('on');
							$("#fmw_id").hide();
							$("#fmw").val("");
							$("#wu-4").siblings().addClass("disable");
							$("#wu-4")[0].classList.add('on');
						});
					}
					if(text == "既往史其他"){
						$("#jws_id").show();
					}else if(text == "家族史其他"){
						$("#jzs_id").show()
					}else if(text == "个人史其他"){
						$("#grs_id").show()
					}else if(text == "阴道分泌物其他"){
						$("#fmw_id").show()
					}else if(text == "保健指导其他"){
						$("#bjzd_id").show()
					}
				}else{
					this.classList.remove('on');
					if(id == "wu-1"){
						$("#wu-1").siblings().removeClass("disable");
					}else if(id == "wu-2"){
						$("#wu-2").siblings().removeClass("disable");
					}else if(id == "wu-3"){
						$("#wu-3").siblings().removeClass("disable");
					}else if(id == "wu-4"){
						$("#wu-4").siblings().removeClass("disable");
					}
					if(text == "既往史其他" && remove_class){
						$("#jws_id").hide();
					}else if(text == "家族史其他" && remove_class){
						$("#jzs_id").hide()
					}else if(text == "个人史其他" && remove_class){
						$("#grs_id").hide()
					}else if(text == "阴道分泌物其他" && remove_class){
						$("#fmw_id").hide()
					}else if(text == "保健指导其他" && remove_class){
						$("#bjzd_id").hide()
					}
				}
			});
			//计算BMI
			var kg = document.getElementById("kg");
			var m = document.getElementById("cm");
			var bmi = document.getElementById("kgm");
			
			kg.addEventListener('input',function(){
				bmi.value = (kg.value/m.value/m.value*10000).toFixed(2);
			});
			m.addEventListener('input',function(){
				bmi.value = (kg.value/m.value/m.value*10000).toFixed(2);
			});
			
			//提交
			var select1 = "",
				select2 = "",
				select3 = "",
				select4 = "",
				select5 = "";
			function submit(){
				//多选1
				select1 = "";
				$ ("#ularry_1").find ('.on').each (function (){
					if($(this).length != 0){
						select1 += $(this).val() + ",";	
					}
				});
				//去掉最后一个逗号(如果不需要去掉，就不用写)
				if (select1.length > 0) {
					select1 = select1.substr(0,select1.length - 1);
				}else{
					select1 = "";
				}
				//多选2
				select2 = "";
				$ ("#ularry_2").find ('.on').each (function (){
					if($(this).length != 0){
						select2 += $(this).val() + ",";	
					}
				});
				//去掉最后一个逗号(如果不需要去掉，就不用写)
				if (select2.length > 0) {
					select2 = select2.substr(0,select2.length - 1);
				}else{
					select2 = "";
				}
				//多选3
				select3 = "";
				$ ("#ularry_3").find ('.on').each (function (){
					if($(this).length != 0){
						select3 += $(this).val() + ",";	
					}
				});
				//去掉最后一个逗号(如果不需要去掉，就不用写)
				if (select3.length > 0) {
					select3 = select3.substr(0,select3.length - 1);
				}else{
					select3 = "";
				}
				//多选4
				select4 = "";
				$ ("#ularry_4").find ('.on').each (function (){
					if($(this).length != 0){
						select4 += $(this).val() + ",";	
					}
				});
				//去掉最后一个逗号(如果不需要去掉，就不用写)
				if (select4.length > 0) {
					select4 = select4.substr(0,select4.length - 1);
				}else{
					select4 = "";
				}
				//多选5
				select5 = "";
				$ ("#ularry_5").find ('.on').each (function (){
					if($(this).length != 0){
						select5 += $(this).val() + ",";	
					}
				});
				//去掉最后一个逗号(如果不需要去掉，就不用写)
				if (select5.length > 0) {
					select5 = select5.substr(0,select5.length - 1);
				}else{
					select5 = "";
				}
				if($("#parity")[0].value == ""){
					alert("请输入胎次")
				}else if($("#result0")[0].value == ""){
					alert("请输入填表时间")
				}else if($("#result9")[0].value == "" && $("#text-doc")[0].value == ""){
					alert("请输入医生签名")
				}else if($("#sugar")[0].value == "" || 
				select4 == "" ||
				$("#yliver_2")[0].value == "" || 
				$("#yliver_3")[0].value == "" || 
				$("#yliver_4")[0].value == "" || 
				$("#yliver_5")[0].value == "" ||
				$("#result6")[0].value == "" ||
				$("#result7")[0].value == "" ||
				$("#Bchao")[0].value == "" ||
				$("#fuzhuother")[0].value == ""){
					alert("请输入带*号的必填项")
				}else{
					alert("可以提交")
					parity = $("#parity")[0].value;
					gestationalWeeks = $("#Weeks_1")[0].value;
					if($("#result0")[0].value != ""){
						visitDate = $("#result0")[0].value+" 00:00:00";
					}else{
						visitDate = "";
					}
					if($("#result8")[0].value != ""){
						nextDate = $("#result8")[0].value+" 00:00:00";
					}else{
						nextDate = "";
					}
					if($("#result1")[0].value != ""){
						result1 = $("#result1")[0].value+" 00:00:00";
					}else{
						result1 = "";
					}
					if($("#result2")[0].value != ""){
						result2 = $("#result2")[0].value+" 00:00:00";
					}else{
						result2 = "";
					}
					var result3_arr = $('#result3')[0].value;
					for(var re=0; re<resultall.r1.length; re++){
						if(result3_arr == resultall.r1[re].text){
							result3 = resultall.r1[re].value;//血型
						};
					};
					var result4_arr = $('#result4')[0].value;
					for(var re=0; re<resultall.r2.length; re++){
						if(result4_arr == resultall.r2[re].text){
							result4 = resultall.r2[re].value;//RH
						};
					};
					var result5_arr = $('#result5')[0].value;
					for(var re=0; re<resultall.r3.length; re++){
						if(result5_arr == resultall.r3[re].text){
							result5 = resultall.r3[re].value;//阴道清洁度
						};
					};
					var result6_arr = $('#result6')[0].value;
					for(var re=0; re<resultall.r4.length; re++){
						if(result6_arr == resultall.r4[re].text){
							result6 = resultall.r4[re].value;//梅毒
						};
					};
					var result7_arr = $('#result7')[0].value;
					for(var re=0; re<resultall.r4.length; re++){
						if(result7_arr == resultall.r4[re].text){
							result7 = resultall.r4[re].value;//HIV
						};
					};
					var data_object =[
						//孕周+
						{
						questionId:"707",
						answerId:0,
						answer:$('#Weeks_2').val()
						},
						//丈夫名
						{
						questionId:"601",
						answerId:0,
						answer:$('#husband_name').val()
						},
						//丈夫年龄
						{
						questionId:"602",
						answerId:0,
						answer:$('#husband_age').val()
						},
						//丈夫电话
						{
						questionId:"603",
						answerId:0,
						answer:$('#husband_tel').val()
						},
						//孕次
						{
						questionId:"585",
						answerId:0,
						answer:$('#attime').val()
						},
						//孕妇年龄
						{
						questionId:"600",
						answerId:0,
						answer:$('#pregnantage').val()
						},
						//阴道分娩
						{
						questionId:"605",
						answerId:0,
						answer:$('#vaginal').val()
						},
						//刨宫产
						{
						questionId:"606",
						answerId:0,
						answer:$('#abdomen').val()
						},
						//末次月经
						{
						questionId:"607",
						answerId:0,
						answer:result1
						},
						//预产期
						{
						questionId:"608",
						answerId:0,
						answer:result2
						},
						//既往史
						{
						questionId:"588",
						answerId:0,
						answer:select1
						},
						//既往史1
						{
						questionId:"657",
						answerId:0,
						answer:$('#jws').val()
						},
						//家族史
						{
						questionId:"589",
						answerId:0,
						answer:select2
						},
						//家族史1
						{
						questionId:"658",
						answerId:0,
						answer:$('#jzs').val()
						},
						//个人史
						{
						questionId:"609",
						answerId:0,
						answer:select3
						},
						//个人史1
						{
						questionId:"659",
						answerId:0,
						answer:$('#grs').val()
						},
						//妇科手术史
						{
						questionId:"610",
						answerId:mySwitch4,
						answer:null
						},
						//妇科手术史1
						{
						questionId:"612",
						answerId:0,
						answer:$('#doc_4').val()
						},
						//自然流产
						{
						questionId:"614",
						answerId:0,
						answer:$('#maternal_1').val()
						},
						//人工流产
						{
						questionId:"704",
						answerId:0,
						answer:$('#maternal_2').val()
						},
						//死胎
						{
						questionId:"615",
						answerId:0,
						answer:$('#maternal_3').val()
						},
						//死产
						{
						questionId:"616",
						answerId:0,
						answer:$('#maternal_4').val()
						},
						//新生儿死亡
						{
						questionId:"617",
						answerId:0,
						answer:$('#maternal_5').val()
						},
						//出生缺陷儿
						{
						questionId:"618",
						answerId:0,
						answer:$('#maternal_6').val()
						},
						//身高
						{
						questionId:"88",
						answerId:0,
						answer:$('#cm').val()
						},
						//体重
						{
						questionId:"89",
						answerId:0,
						answer:$('#kg').val()
						},
						//体重
						{
						questionId:"91",
						answerId:0,
						answer:$('#kgm').val()
						},
						//血压1
						{
						questionId:"85",
						answerId:0,
						answer:$('#sbp').val()
						},
						//血压2
						{
						questionId:"86",
						answerId:0,
						answer:$('#dbp').val()
						},
						//心脏
						{
						questionId:"620",
						answerId:mySwitch5,
						answer:null
						},
						//心脏1
						{
						questionId:"621",
						answerId:0,
						answer:$('#doc_5').val()
						},
						//肺部
						{
						questionId:"622",
						answerId:mySwitch6,
						answer:null
						},
						//肺部1
						{
						questionId:"623",
						answerId:0,
						answer:$('#doc_6').val()
						},
						//外阴
						{
						questionId:"141",
						answerId:mySwitch7,
						answer:null
						},
						//外阴1
						{
						questionId:"142",
						answerId:0,
						answer:$('#doc_7').val()
						},
						//阴道
						{
						questionId:"143",
						answerId:mySwitch8,
						answer:null
						},
						//阴道1
						{
						questionId:"144",
						answerId:0,
						answer:$('#doc_8').val()
						},
						//宫颈
						{
						questionId:"145",
						answerId:mySwitch9,
						answer:null
						},
						//宫颈1
						{
						questionId:"146",
						answerId:0,
						answer:$('#doc_9').val()
						},
						//子宫
						{
						questionId:"147",
						answerId:mySwitch10,
						answer:null
						},
						//子宫1
						{
						questionId:"148",
						answerId:0,
						answer:$('#doc_10').val()
						},
						//附件
						{
						questionId:"149",
						answerId:mySwitch11,
						answer:null
						},
						//附件1
						{
						questionId:"150",
						answerId:0,
						answer:$('#doc_11').val()
						},
						//血红蛋白值
						{
						questionId:"161",
						answerId:0,
						answer:$('#blood_1').val()
						},
						//白细胞计数值
						{
						questionId:"162",
						answerId:0,
						answer:$('#blood_2').val()
						},
						//血小板计数值
						{
						questionId:"163",
						answerId:0,
						answer:$('#blood_3').val()
						},
						//其他
						{
						questionId:"164",
						answerId:0,
						answer:$('#blood_4').val()
						},
						//尿蛋白
						{
						questionId:"165",
						answerId:0,
						answer:$('#urine_1').val()
						},
						//尿糖
						{
						questionId:"166",
						answerId:0,
						answer:$('#urine_2').val()
						},
						//尿酮体
						{
						questionId:"167",
						answerId:0,
						answer:$('#urine_3').val()
						},
						//尿潜血
						{
						questionId:"168",
						answerId:0,
						answer:$('#urine_4').val()
						},
						//其它
						{
						questionId:"169",
						answerId:0,
						answer:$('#urine_5').val()
						},
						//血型
						{
						questionId:"13",
						answerId:result3,
						answer:null
						},
						//RH
						{
						questionId:"26",
						answerId:result4,
						answer:null
						},
						//血糖
						{
						questionId:"160",
						answerId:0,
						answer:$('#sugar').val()
						},
						//肝功能1
						{
						questionId:"172",
						answerId:0,
						answer:$('#liver_1').val()
						},
						//肝功能2
						{
						questionId:"173",
						answerId:0,
						answer:$('#liver_2').val()
						},
						//肝功能3
						{
						questionId:"174",
						answerId:0,
						answer:$('#liver_3').val()
						},
						//肝功能4
						{
						questionId:"175",
						answerId:0,
						answer:$('#liver_4').val()
						},
						//肝功能5
						{
						questionId:"176",
						answerId:0,
						answer:$('#liver_5').val()
						},
						//肾功能1
						{
						questionId:"177",
						answerId:0,
						answer:$('#renal_1').val()
						},
						//肾功能2
						{
						questionId:"178",
						answerId:0,
						answer:$('#renal_2').val()
						},
						//阴道分泌物
						{
						questionId:"626",
						answerId:0,
						answer:select4
						},
						//阴道分泌物其它
						{
						questionId:"627",
						answerId:0,
						answer:$('#fmw').val()
						},
						//阴道清洁度
						{
						questionId:"628",
						answerId:result5,
						answer:null
						},
						//乙肝1
						{
						questionId:"629",
						answerId:0,
						answer:$('#yliver_1').val()
						},
						//乙肝2
						{
						questionId:"630",
						answerId:0,
						answer:$('#yliver_2').val()
						},
						//乙肝3
						{
						questionId:"631",
						answerId:0,
						answer:$('#yliver_3').val()
						},
						//乙肝4
						{
						questionId:"632",
						answerId:0,
						answer:$('#yliver_4').val()
						},
						//乙肝5
						{
						questionId:"633",
						answerId:0,
						answer:$('#yliver_5').val()
						},
						//梅毒血清
						{
						questionId:"634",
						answerId:result6,
						answer:null
						},
						//HIV抗体
						{
						questionId:"635",
						answerId:result7,
						answer:null
						},
						//B超
						{
						questionId:"194",
						answerId:0,
						answer:$('#Bchao').val()
						},
						//其它
						{
						questionId:"440",
						answerId:0,
						answer:$('#fuzhuother').val()
						},
						//总体评估
						{
						questionId:"636",
						answerId:mySwitch12,
						answer:null
						},
						//总体评估1
						{
						questionId:"637",
						answerId:0,
						answer:$('#doc_12').val()
						},
						//保健指导
						{
						questionId:"638",
						answerId:0,
						answer:select5
						},
						//保健指导其它
						{
						questionId:"587",
						answerId:0,
						answer:$('#bjzd').val()
						},
						//转诊
						{
						questionId:"332",
						answerId:mySwitch13,
						answer:null
						},
						//原因
						{
						questionId:"333",
						answerId:0,
						answer:$('#chuli_why').val()
						},
						//科室
						{
						questionId:"334",
						answerId:0,
						answer:$('#chuli_det').val()
						},
						//备注
						{
						questionId:"584",
						answerId:0,
						answer:$('#note').val()
						}
					]
					console.log(data_object)
					$.ajax(getRequestUrl.url+"/mobile/ehr/MaternalHealth/addOrUpdate",{
						data:{
							id : id,
							ehrId : ehrId,
							parity : parity,//胎次
							visitLevel : visitLevel,//1、产前第一次随访 2、产前2-5次随访 3、产后随访 4、产后24天随访
							visitDate : visitDate,//随访时间
							nextDate : nextDate,
							doctorName : doctorName,
							visitItem : visitItem,
							gestationalWeeks : gestationalWeeks,
							createUser : createUser,
							updateUser : updateUser,
							createDate : createDate,
							updateDate : updateDate,
							enableFlag : enableFlag,
							doctorId : doctorId,
							doctorHospId : doctorHospId,
							doctorHospName : doctorHospName,
							xkSign : xkSign,
							ipOutDate : ipOutDate,
							childbirthDate : childbirthDate,
							versionNum : versionNum,
							ifVisit : ifVisit,
							readcardCheck : readcardCheck
							},
						dataType:'json',//服务器返回json格式数据
						type:'post',//HTTP请求类型
						timeout:10000,//超时时间设置为10秒；
						success:function(data){
							console.log("成功1")
							if(data.status == 1){
								var mid = data.total;
								for(var i=0; i<data_object.length; i++){
									data_object[i].ehrId = ehrId;
									data_object[i].mid = mid;
								}
								$.ajax(getRequestUrl.url+"/mobile/ehr/maternalHealthAnswer/addOrUpdate",{
									data:JSON.stringify(data_object),
									dataType:'json',//服务器返回json格式数据
									type:'post',//HTTP请求类型
									contentType : 'application/json;charset=utf-8',
									success:function(data){
										console.log("成功")
									},
									error:function(xhr,type,errorThrown){
										
									}
								});	
							}
						},
						error:function(xhr,type,errorThrown){
							
						}
					});
				}
			}
		</script>
	</body>
</html>